#!/usr/bin/env python
# -*- encoding: utf-8 -*-
# Project: spd-sxmcc
"""
@author: lyndon
@time Created on 2018/10/11 15:39
@desc 计算 1 - 2 + 3 ... 99 中，除了88以外的所有数的总和
"""

lis = [i for i in range(100)]
sum = 0
formula = ""
for i in lis:
    if i == 88:
        i += 1
        continue
    if i % 2 == 0:
        sum -= i
        formula = formula + " - " + str(i)
    else:
        sum += i
        formula = formula + " + " + str(i)
print(formula)
print(sum)


